An arithmetic logic unit (ALU) is a structure for an integer operation. The ALU is a digital circuit specialized for executing arithmetic and logic operations in a computer. The ALU is the most important component of a central processing unit of the computer, and even a microprocessor also includes an ALU functioning to count. Modern CPU (central processing unit) and GPU (Graphics Processing Unit) have already included powerful and complicated ALUs; a single element may also include an ALU. Most of the ALUs can complete the following operations: an integer arithmetic operation (addition, subtraction, multiplication and division are sometimes included, but cost much), a bit logical operation (AND, OR, NOT, XOR), and a shift operation (shifting or floating data to left or right by certain bits), and shifting may be considered as being multiplied or divided by 2. Generally, an arithmetic logic unit only includes a linear operation part, and when the arithmetic logic unit performs complicated operations such as exponentiation operation, it often requires several operation periods.
In order to accelerate an operation speed of a processor, a FPU (Floating-Point Unit) is often integrated in a CPU and a GPU. The FPU is a processor specialized for a floating-point operation, and may support calculation of some transcendental functions, such as, log 2x. The operation speed of the FPU is much faster than the ALU.
In the prior art, when calculating a nonlinear function, a complicated operation is often divided to simply operations, and a result can be obtained after several operation periods, which makes the operation speed slow, an area of the operation device large, and power consumption high.